Skip to content

Rollup of 6 pull requests #139147

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 13 commits into from
Closed

Conversation

jhpratt
Copy link
Member

@jhpratt jhpratt commented Mar 30, 2025

Successful merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

thaliaarchi and others added 13 commits March 28, 2025 14:45
this uses some # directives to make sure the code works on x86_64, and does not produce errors on other platforms
Before:

    let a =
        StructWithSomeFields{
            field_1: 1,

            field_2: 2,

            field_3: 3,

            field_4: 4,

            field_5: 5,

            field_6: 6,};

    let a = StructWithSomeFields{ field_1: 1,  field_2: 2, ..a};

After:

    let a =
        StructWithSomeFields {
            field_1: 1,
            field_2: 2,
            field_3: 3,
            field_4: 4,
            field_5: 5,
            field_6: 6 };

    let a = StructWithSomeFields { field_1: 1, field_2: 2, ..a };
…one, r=onur-ozkan

bootstrap: Avoid cloning `change-id` list

Inspired by [recent discussion](https://rust-lang.zulipchat.com/#narrow/channel/326414-t-infra.2Fbootstrap/topic/Collecting.20some.20Real.20Configs.20for.20testing/near/507845657) on the bootstrap `change-id` field, I took a look at the code and found this little optimization. It does not change behavior.
…-check-block, r=GuillaumeGomez

unstable book: in a sanitizer example, check the code

Use some `#` directives to make sure the code checks on x86_64, and does not produce errors on other platforms. This example still used an older version of `#[naked]`, and because the snippet was ignored that was missed before.

I'm not sure when this gets built on CI exactly, so it might be worthwhile to try and build it for a non-x86_64 architecture to make sure that works. I'm not sure how to verify locally that e.g. on aarch64 this code works without errors/warnings.
…rors

Remove attribute `#[rustc_error]`

It was an ancient way to write `check-pass` tests, but now it's no longer necessary (except for the `delayed_bug_from_inside_query` flavor, which is retained).
…iler-errors

Improve hir_pretty for struct expressions.

While working on rust-lang#139131 I noticed the hir pretty printer outputs an empty line between each field, and is also missing a space before the `{` and the `}`:

```rust
    let a =
        StructWithSomeFields{
            field_1: 1,

            field_2: 2,

            field_3: 3,

            field_4: 4,

            field_5: 5,

            field_6: 6,};

    let a = StructWithSomeFields{ field_1: 1,  field_2: 2, ..a};
```

This changes it to:

```rust
    let a =
        StructWithSomeFields {
            field_1: 1,
            field_2: 2,
            field_3: 3,
            field_4: 4,
            field_5: 5,
            field_6: 6 };

    let a = StructWithSomeFields { field_1: 1, field_2: 2, ..a };
```
Switch some rustc_on_unimplemented uses to diagnostic::on_unimplemented

The use on the SliceIndex impl appears unreachable, there is no mention of "vector indices" in any test output and I could not get it to show up in error messages.
@rustbot rustbot added PG-exploit-mitigations Project group: Exploit mitigations S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue. rollup A PR which is a rollup labels Mar 30, 2025
@jhpratt
Copy link
Member Author

jhpratt commented Mar 30, 2025

@bors r+ rollup=never p=5

@bors
Copy link
Collaborator

bors commented Mar 30, 2025

📌 Commit b6349e2 has been approved by jhpratt

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Mar 30, 2025
bors added a commit to rust-lang-ci/rust that referenced this pull request Mar 30, 2025
Rollup of 6 pull requests

Successful merges:

 - rust-lang#139044 (bootstrap: Avoid cloning `change-id` list)
 - rust-lang#139111 (Properly document FakeReads)
 - rust-lang#139113 (unstable book: in a sanitizer example, check the code)
 - rust-lang#139122 (Remove attribute `#[rustc_error]`)
 - rust-lang#139132 (Improve hir_pretty for struct expressions.)
 - rust-lang#139141 (Switch some rustc_on_unimplemented uses to diagnostic::on_unimplemented)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors
Copy link
Collaborator

bors commented Mar 30, 2025

⌛ Testing commit b6349e2 with merge 07c1d0a...

@rust-log-analyzer
Copy link
Collaborator

The job aarch64-apple failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)

failures:

---- /Users/runner/work/rust/rust/src/doc/unstable-book/src/compiler-flags/sanitizer.md - ControlFlowIntegrity::Example_1__Redirecting_control_flow_using_an_indirect_branch_call_to_an_invalid_destination (line 247) stdout ----
Test executable failed (signal: 10 (SIGBUS)).

stdout:
The answer is: 12
With CFI enabled, you should not see the next answer



failures:
    /Users/runner/work/rust/rust/src/doc/unstable-book/src/compiler-flags/sanitizer.md - ControlFlowIntegrity::Example_1__Redirecting_control_flow_using_an_indirect_branch_call_to_an_invalid_destination (line 247)

test result: FAILED. 7 passed; 1 failed; 2 ignored; 0 measured; 0 filtered out; finished in 0.34s

Command has failed. Rerun with -v to see more details.
Build completed unsuccessfully in 0:50:52
  local time: Sun Mar 30 21:57:08 UTC 2025
  network time: Sun, 30 Mar 2025 21:57:08 GMT
##[error]Process completed with exit code 1.
Post job cleanup.

@bors
Copy link
Collaborator

bors commented Mar 30, 2025

💔 Test failed - checks-actions

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Mar 30, 2025
@jhpratt jhpratt closed this Mar 30, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PG-exploit-mitigations Project group: Exploit mitigations rollup A PR which is a rollup S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants